//      config.h
//      
//      Copyright 2012 dimir <dimir@dimir-pc>
//      
//      This program is free software; you can redistribute it and/or modify
//      it under the terms of the GNU General Public License as published by
//      the Free Software Foundation; either version 2 of the License, or
//      (at your option) any later version.
//      
//      This program is distributed in the hope that it will be useful,
//      but WITHOUT ANY WARRANTY; without even the implied warranty of
//      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//      GNU General Public License for more details.
//      
//      You should have received a copy of the GNU General Public License
//      along with this program; if not, write to the Free Software
//      Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
//      MA 02110-1301, USA.
//      
//      


#ifndef CONFIG_H
#define CONFIG_H

#include <string>
#include <map>
#include <fstream>

static const char* TAG_MAP = "map";
static const char* TAG_PLAYER_1 = "player1";
static const char* TAG_PLAYER_2 = "player2";
static const char* TAG_PLAYER_1_STDIN = "pipe_player1_stdin";
static const char* TAG_PLAYER_1_STDOUT = "pipe_player1_stdout";
static const char* TAG_PLAYER_2_STDIN = "pipe_player2_stdin";
static const char* TAG_PLAYER_2_STDOUT = "pipe_player2_stdout";
static const char* TAG_CHECKER = "checker";


class Config
{
	public:
		Config(const std::string& path_to_config);
		std::string getPathToMap();
		std::string getPathToPlayer1();
		std::string getPathToPlayer2();
		std::string getPathToPlayer1STDIN();
		std::string getPathToPlayer1STDOUT();
		std::string getPathToPlayer2STDIN();
		std::string getPathToPlayer2STDOUT();
		std::string getPathToChecker();
			
	private:
		/* add your private declarations */
		

		std::map<std::string, std::string> tags_value;
		std::string getValue(const std::string& tag_name);
};

#endif /* CONFIG_H */ 
